<div class="form">

    <?php $form = $this->beginWidget('CActiveForm', array(
    'id' => 'contract-documents-form',
    'enableAjaxValidation' => false,
)); ?>

    <p class="note">Fields with <span class="required">*</span> are required.</p>

    <?php echo $form->errorSummary($model); ?>

    <div class="row">
        <?php echo $form->labelEx($model, 'docname'); ?>
        <?php echo $form->textField($model, 'docname', array('size' => 60, 'maxlength' => 150)); ?>
        <?php echo $form->error($model, 'docname'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'filename'); ?>
        <?php echo $form->textField($model, 'filename', array('size' => 60, 'maxlength' => 255)); ?>
        <?php echo $form->error($model, 'filename'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'dateadded'); ?>
        <?php echo $form->textField($model, 'dateadded'); ?>
        <?php echo $form->error($model, 'dateadded'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'addedby'); ?>
        <?php echo $form->textField($model, 'addedby', array('size' => 60, 'maxlength' => 255)); ?>
        <?php echo $form->error($model, 'addedby'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'notes'); ?>
        <?php echo $form->textArea($model, 'notes', array('rows' => 6, 'cols' => 50)); ?>
        <?php echo $form->error($model, 'notes'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'locktime'); ?>
        <?php echo $form->textField($model, 'locktime', array('size' => 20, 'maxlength' => 20)); ?>
        <?php echo $form->error($model, 'locktime'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'lockby'); ?>
        <?php echo $form->textField($model, 'lockby', array('size' => 30, 'maxlength' => 30)); ?>
        <?php echo $form->error($model, 'lockby'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'contractid'); ?>
        <?php echo $form->textField($model, 'contractid', array('size' => 41, 'maxlength' => 41)); ?>
        <?php echo $form->error($model, 'contractid'); ?>
    </div>

    <div class="row buttons">
        <?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
    </div>

    <?php $this->endWidget(); ?>

</div><!-- form -->